﻿using Microsoft.Extensions.Hosting;
using System.Runtime.InteropServices.JavaScript;

namespace FlyingEye
{
    internal class Startup
    {
        public static IHost Run()
        {
            var builder = Host.CreateDefaultBuilder();
            var configuration = new FlyingEyeAdminModule();
            configuration.ConfigureHost(builder);
            builder.ConfigureServices((context, services) =>
            {
                configuration.ConfigureServices(context, services);
            });
            var host = builder.Build();
            host.Start();

            return host;
        }
    }
}
